home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1995 August: Tool Chest / Dev.CD Aug 95 TC / Dev.CD Aug 95 TC.toast / Tool Chest / Interfaces / UniversalInterfaces 2.1B1 / CIncludes / OCETemplates.h < prev    next >
Encoding:
C/C++ Source or Header  |  1995-04-18  |  51.2 KB  |  1,570 lines  |  [TEXT/MPS ]

  1. /*
  2.      File:        OCETemplates.h
  3.  
  4.      Contains:    Apple Open Collaboration Environment Templates Interfaces.
  5.  
  6.      Version:    Technology:    AOCE Toolbox 1.02
  7.                  Package:    Universal Interfaces 2.1ß1 in “MPW Prerelease” on ETO #17
  8.  
  9.      Copyright:    © 1984-1995 by Apple Computer, Inc.
  10.                  All rights reserved.
  11.  
  12.      Bugs?:        If you find a problem with this file, use the Apple Bug Reporter
  13.                  stack.  Include the file and version information (from above)
  14.                  in the problem description and send to:
  15.                      Internet:    apple.bugs@applelink.apple.com
  16.                      AppleLink:    APPLE.BUGS
  17.  
  18. */
  19.  
  20. #ifndef __OCETEMPLATES__
  21. #define __OCETEMPLATES__
  22.  
  23. #ifndef REZ
  24.  
  25. #ifndef __TYPES__
  26. #include <Types.h>
  27. #endif
  28. /*    #include <ConditionalMacros.h>                                */
  29.  
  30. #ifndef __EVENTS__
  31. #include <Events.h>
  32. #endif
  33. /*    #include <Quickdraw.h>                                        */
  34. /*        #include <MixedMode.h>                                    */
  35. /*        #include <QuickdrawText.h>                                */
  36. /*    #include <OSUtils.h>                                        */
  37. /*        #include <Memory.h>                                        */
  38.  
  39. #ifndef __CONTROLS__
  40. #include <Controls.h>
  41. #endif
  42. /*    #include <Menus.h>                                            */
  43.  
  44. #ifndef __APPLEEVENTS__
  45. #include <AppleEvents.h>
  46. #endif
  47. /*    #include <Errors.h>                                            */
  48. /*    #include <EPPC.h>                                            */
  49. /*        #include <AppleTalk.h>                                    */
  50. /*        #include <Files.h>                                        */
  51. /*        #include <PPCToolbox.h>                                    */
  52. /*        #include <Processes.h>                                    */
  53. /*    #include <Notification.h>                                    */
  54.  
  55. #ifndef __DIALOGS__
  56. #include <Dialogs.h>
  57. #endif
  58. /*    #include <Windows.h>                                        */
  59. /*    #include <TextEdit.h>                                        */
  60. #endif /* REZ */
  61.  
  62. #ifndef __OCE__
  63. #include <OCE.h>
  64. #endif
  65. /*    #include <Aliases.h>                                        */
  66. /*    #include <Script.h>                                            */
  67. /*        #include <IntlResources.h>                                */
  68. #ifndef REZ
  69.  
  70. #ifndef __OCESTANDARDMAIL__
  71. #include <OCEStandardMail.h>
  72. #endif
  73. /*    #include <OCEAuthDir.h>                                        */
  74. /*    #include <OCEMail.h>                                        */
  75. /*        #include <DigitalSignature.h>                            */
  76. /*        #include <OCEMessaging.h>                                */
  77.  
  78. #ifdef __cplusplus
  79. extern "C" {
  80. #endif
  81.  
  82. #if PRAGMA_ALIGN_SUPPORTED
  83. #pragma options align=mac68k
  84. #endif
  85.  
  86. #if PRAGMA_IMPORT_SUPPORTED
  87. #pragma import on
  88. #endif
  89.  
  90. #endif /* REZ */
  91. #define kDETAspectVersion -976
  92. #define kDETInfoPageVersion -976
  93. #define kDETKillerVersion -976
  94. #define kDETForwarderVersion -976
  95. #define kDETFileTypeVersion -976
  96. #define kDETIDSep 250
  97. #define kDETFirstID (1000)
  98. #define kDETSecondID (1000+kDETIDSep)
  99. #define kDETThirdID (1000+2*kDETIDSep)
  100. #define kDETFourthID (1000+3*kDETIDSep)
  101. #define kDETFifthID (1000+4*kDETIDSep)
  102. #define kDETTemplateName 0
  103. #define kDETRecordType 1
  104. #define kDETAttributeType 2
  105. #define kDETAttributeValueTag 3
  106. #define kDETAspectCode 4
  107. #define kDETAspectMainBitmap 5
  108. #define kDETAspectName 6
  109. #define kDETAspectCategory 7
  110. #define kDETAspectExternalCategory 8
  111. #define kDETAspectKind 9
  112. #define kDETAspectGender 10
  113. #define kDETAspectWhatIs 11
  114. #define kDETAspectAliasKind 12
  115. #define kDETAspectAliasGender 13
  116. #define kDETAspectAliasWhatIs 14
  117. #define kDETAspectBalloons 15
  118. #define kDETAspectNewMenuName 16
  119. #define kDETAspectNewEntryName 17
  120. #define kDETAspectNewValue 18
  121. #define kDETAspectSublistOpenOnNew 19
  122. #define kDETAspectLookup 20
  123. #define kDETAspectDragInString 21
  124. #define kDETAspectDragInVerb 22
  125. #define kDETAspectDragInSummary 23
  126. #define kDETAspectRecordDragIn 24
  127. #define kDETAspectRecordCatDragIn 25
  128. #define kDETAspectAttrDragIn 26
  129. #define kDETAspectAttrDragOut 27
  130. #define kDETAspectViewMenu 28
  131. #define kDETAspectReverseSort 29
  132. #define kDETAspectInfoPageCustomWindow 30
  133. #define kDETNoProperty -1
  134. #define kDETFirstLocalProperty 0
  135. #define kDETLastLocalProperty (kDETFirstLocalProperty+249)
  136. #define kDETFirstDevProperty 40
  137. #define kDETFirstConstantProperty 250
  138. #define kDETLastConstantProperty (kDETFirstConstantProperty+249)
  139. #define kDETConstantProperty kDETFirstConstantProperty
  140. #define kDETZeroProperty (kDETConstantProperty+0)
  141. #define kDETOneProperty (kDETConstantProperty+1)
  142. #define kDETFalseProperty (kDETConstantProperty+0)
  143. #define kDETTrueProperty (kDETConstantProperty+1)
  144. #define kDETPrName 3050
  145. #define kDETPrKind 3051
  146. #define kDETDNodeAccessMask 25825
  147. #define kDETRecordAccessMask 25826
  148. #define kDETAttributeAccessMask 25827
  149. #define kDETPrimaryMaskByBit 25828
  150. #define kDETPrimarySeeMask kDETPrimaryMaskByBit
  151. #define kDETPrimaryAddMask (kDETPrimaryMaskByBit+1)
  152. #define kDETPrimaryDeleteMask (kDETPrimaryMaskByBit+2)
  153. #define kDETPrimaryChangeMask (kDETPrimaryMaskByBit+3)
  154. #define kDETPrimaryRenameMask (kDETPrimaryMaskByBit+4)
  155. #define kDETPrimaryChangePrivsMask (kDETPrimaryMaskByBit+5)
  156. #define kDETPrimaryTopMaskBit (kDETPrimaryMaskByBit+15)
  157. #define kDETPastFirstLookup 26550
  158. #define kDETInfoPageNumber 27050
  159. #define kDETAspectTemplateNumber 26551
  160. #define kDETInfoPageTemplateNumber 26552
  161. #define kDETOpenSelectedItems 26553
  162. #define kDETAddNewItem 26554
  163. #define kDETRemoveSelectedItems 26555
  164. #define kDETPrTypeNumber -1
  165. #define kDETPrTypeString -2
  166. #define kDETPrTypeBinary -3
  167. #ifdef REZ
  168. #define typeRString 'rstr'
  169. #define typePackedDSSpec 'dspc'
  170. #define typeBinary 'bnry'
  171. #endif
  172. #define kDETInfoPageName 4
  173. #define kDETInfoPageMainViewAspect 5
  174. #define kDETInfoPageMenuName 6
  175. #define kDETInfoPageMenuEntries 7
  176. #define kDETNoFlags 0
  177. #define kDETEnabled (1 << 0)
  178. #define kDETHilightIfSelected (1 << 0)
  179. #define kDETNumericOnly (1 << 3)
  180. #define kDETMultiLine (1 << 4)
  181. #define kDETDynamicSize (1 << 9)
  182. #define kDETAllowNoColons (1 << 10)
  183. #define kDETPopupDynamicSize (1 << 8)
  184. #define kDETScaleToView (1 << 8)
  185. #define kDETLargeIcon 0
  186. #define kDETSmallIcon 1
  187. #define kDETMiniIcon 2
  188. #define kDETLeft 0
  189. #define kDETCenter 1
  190. #define kDETRight -1
  191. #define kDETForceLeft -2
  192. #define kDETUnused 0
  193. #define kDETBoxTakesContentClicks (1 << 0)
  194. #define kDETBoxIsRounded (1 << 1)
  195. #define kDETBoxIsGrayed (1 << 2)
  196. #define kDETBoxIsInvisible (1 << 3)
  197. #define kDETApplicationFont 1
  198. #define kDETApplicationFontSize 9
  199. #define kDETAppFontLineHeight 12
  200. #define kDETSystemFont 0
  201. #define kDETSystemFontSize 12
  202. #define kDETSystemFontLineHeight 16
  203. #define kDETDefaultFont 1
  204. #define kDETDefaultFontSize 9
  205. #define kDETDefaultFontLineHeight 12
  206. #define kDETNormal 0
  207. #define kDETBold 1
  208. #define kDETItalic 2
  209. #define kDETUnderline 4
  210. #define kDETOutline 8
  211. #define kDETShadow 0x10
  212. #define kDETCondense 0x20
  213. #define kDETExtend 0x40
  214. #define kDETIconStyle -3
  215. #define kDETChangeViewCommand 'view'
  216. #define kDETRecordInfoWindHeight 228
  217. #define kDETRecordInfoWindWidth 400
  218. #define kDETAttributeInfoWindHeight 250
  219. #define kDETAttributeInfoWindWidth 230
  220. #define kDETSubpageIconTop 8
  221. #define kDETSubpageIconLeft 8
  222. #define kDETSubpageIconBottom (kDETSubpageIconTop+32)
  223. #define kDETSubpageIconRight (kDETSubpageIconLeft+32)
  224. #define kDETSubpageIconRect {kDETSubpageIconTop, kDETSubpageIconLeft, kDETSubpageIconBottom, kDETSubpageIconRight}
  225. #define kDETNoSublistRect {0, 0, 0, 0}
  226. #define kDETKillerName 1
  227. #define kDETForwarderTemplateNames 4
  228. #define kDETCategoryAllItems "aoce All Items"
  229. #define kDETCategoryAddressItems "aoce Address Items"
  230. #define kDETCategoryMisc "aoce Miscellaneous"
  231. #ifndef REZ
  232. /* Target specification: */
  233.  
  234. enum {
  235.     kDETSelf                    = 0,                            /* The "current" item */
  236.     kDETSelfOtherAspect,                                        /* Another aspect of the current item */
  237.     kDETParent,                                                    /* The parent (i.e., the aspect we're in the sublist of, if any) of the current item */
  238.     kDETSublistItem,                                            /* The itemNumberth item in the sublist */
  239.     kDETSelectedSublistItem,                                    /* The itemNumberth selected item in the sublist */
  240.     kDETDSSpec,                                                    /* The item specified by the packed DSSpec */
  241.     kDETAspectTemplate,                                            /* A specific aspect template (number itemNumber) */
  242.     kDETInfoPageTemplate,                                        /* A specific info-page template (number itemNumber)
  243.     *  Force type to be short */
  244.     kDETHighSelector            = 0xF000
  245. };
  246.  
  247. typedef long DETTargetSelector;
  248.  
  249. struct DETTargetSpecification {
  250.     DETTargetSelector                selector;                    /* Target selection method (see above) */
  251.     RStringPtr                        aspectName;                    /* The name of the aspect (kDETSelfOtherAspect, kDETSublistItem,
  252.                                            kDETSelectedSublistItem, kDETDSSpec); nil for main aspect or none;
  253.                                            always filled in for calls if there is an aspect, even if it's the main aspect */
  254.     long                            itemNumber;                    /* Sublist index (kDETSublistItem & kDETSelectedSublistItem & kDETAspectTemplate);
  255.                                            1-based indexing */
  256.     PackedDSSpecPtr                    dsSpec;                        /* DSSpec (kDETDSSpec only) */
  257. };
  258.  
  259. typedef struct DETTargetSpecification DETTargetSpecification;
  260.  
  261. /* Code resource calls and call-backs both return an OSType:
  262.         kDETDidNotHandle (1)    = used by template to say "I didn't handle it" (for calls only)
  263.         noErr                    = function completed successfully
  264.         any error                = function failed, and here's why
  265. */
  266. #define kDETDidNotHandle 1
  267.  
  268. enum {
  269.     kDETcmdSimpleCallback        = 0,
  270.     kDETcmdBeep,
  271.     kDETcmdBusy,
  272.     kDETcmdChangeCallFors,
  273.     kDETcmdGetCommandSelectionCount,
  274.     kDETcmdGetCommandItemN,
  275.     kDETcmdOpenDSSpec,
  276.     kDETcmdAboutToTalk,
  277.     kDETcmdUnloadTemplates,
  278.     kDETcmdTemplateCounts,
  279.     kDETcmdTargetedCallback        = 1000,
  280.     kDETcmdGetDSSpec,
  281.     kDETcmdSublistCount,
  282.     kDETcmdSelectedSublistCount,
  283.     kDETcmdRequestSync,
  284.     kDETcmdBreakAttribute,
  285.     kDETcmdGetTemplateFSSpec,
  286.     kDETcmdGetOpenEdit,
  287.     kDETcmdCloseEdit,
  288.     kDETcmdPropertyCallback        = 2000,
  289.     kDETcmdGetPropertyType,
  290.     kDETcmdGetPropertyNumber,
  291.     kDETcmdGetPropertyRString,
  292.     kDETcmdGetPropertyBinarySize,
  293.     kDETcmdGetPropertyBinary,
  294.     kDETcmdGetPropertyChanged,
  295.     kDETcmdGetPropertyEditable,
  296.     kDETcmdSetPropertyType,
  297.     kDETcmdSetPropertyNumber,
  298.     kDETcmdSetPropertyRString,
  299.     kDETcmdSetPropertyBinary,
  300.     kDETcmdSetPropertyChanged,
  301.     kDETcmdSetPropertyEditable,
  302.     kDETcmdDirtyProperty,
  303.     kDETcmdDoPropertyCommand,
  304.     kDETcmdAddMenu,
  305.     kDETcmdRemoveMenu,
  306.     kDETcmdMenuItemRString,
  307.     kDETcmdSaveProperty,
  308.     kDETcmdGetCustomViewUserReference,
  309.     kDETcmdGetCustomViewBounds,
  310.     kDETcmdGetResource,
  311. /* Force type to be long */
  312.     kDETcmdHighCallback            = 0xF0000000
  313. };
  314.  
  315. typedef unsigned long DETCallBackFunctions;
  316.  
  317. #define DETCallBackBlockHeader     \
  318.     DETCallBackFunctions reqFunction;
  319. #define DETCallBackBlockTargetedHeader  \
  320.     DETCallBackFunctions reqFunction;     \
  321.     DETTargetSpecification target;
  322. #define DETCallBackBlockPropertyHeader  \
  323.     DETCallBackFunctions reqFunction;     \
  324.     DETTargetSpecification target;     \
  325.     short property;
  326. struct DETProtoCallBackBlock {
  327.     DETCallBackFunctions            reqFunction;
  328.     DETTargetSpecification            target;
  329.     short                            property;
  330. };
  331.  
  332. typedef struct DETProtoCallBackBlock DETProtoCallBackBlock;
  333.  
  334. struct DETBeepBlock {
  335.     DETCallBackFunctions            reqFunction;
  336. };
  337.  
  338. typedef struct DETBeepBlock DETBeepBlock;
  339.  
  340. struct DETBusyBlock {
  341.     DETCallBackFunctions            reqFunction;
  342. };
  343.  
  344. typedef struct DETBusyBlock DETBusyBlock;
  345.  
  346. struct DETChangeCallForsBlock {
  347.     DETCallBackFunctions            reqFunction;
  348.     DETTargetSpecification            target;
  349.     long                            newCallFors;                /*  -> New call-for mask */
  350. };
  351.  
  352. typedef struct DETChangeCallForsBlock DETChangeCallForsBlock;
  353.  
  354. struct DETGetCommandSelectionCountBlock {
  355.     DETCallBackFunctions            reqFunction;
  356.     long                            count;                        /* <-  The number of items in the command selection list */
  357. };
  358.  
  359. typedef struct DETGetCommandSelectionCountBlock DETGetCommandSelectionCountBlock;
  360.  
  361.  
  362. enum {
  363.     kDETHFSType                    = 0,                            /* HFS item type */
  364.     kDETDSType,                                                    /* Catalog Service item type */
  365.     kDETMailType,                                                /* Mail (letter) item type */
  366.     kDETMoverType,                                                /* Sounds, fonts, etc., from inside a suitcase or system file */
  367.     kDETLastItemType            = 0xF0000000                    /* Force it to be a long (C & C++ seem to disagree about the definition of 0xF000) */
  368. };
  369.  
  370. typedef unsigned long DETItemType;
  371.  
  372. /* FSSpec plus possibly interesting additional info */
  373. struct DETFSInfo {
  374.     OSType                            fileType;                    /* File type */
  375.     OSType                            fileCreator;                /* File creator */
  376.     unsigned short                    fdFlags;                    /* Finder flags */
  377.     FSSpec                            fsSpec;                        /* FSSpec */
  378. };
  379.  
  380. typedef struct DETFSInfo DETFSInfo;
  381.  
  382. struct DSRec {
  383.     PackedDSSpecPtr                    *dsSpec;                    /* <-  DSSpec for item (caller must DisposHandle() when done) */
  384.     short                            refNum;                        /* <-  Refnum for returned address */
  385.     AuthIdentity                    identity;                    /* <-  Identity for returned address */
  386. };
  387.  
  388. typedef struct DSRec DSRec;
  389.  
  390. union ItemRec {
  391.     DETFSInfo                        **fsInfo;                    /* <-  FSSpec & info for item (caller must DisposHandle() when done) */
  392.     DSRec                            ds;
  393.     PackedDSSpecPtr                    *dsSpec;                    /* <-  DSSpec for item (caller must DisposHandle() when done) */
  394.     LetterSpec                        **ltrSpec;                    /* <-  Letter spec for item (caller must DisposHandle() when done) */
  395. };
  396. typedef union ItemRec ItemRec;
  397.  
  398. struct DETGetCommandItemNBlock {
  399.     DETCallBackFunctions            reqFunction;
  400.     long                            itemNumber;                    /*  -> Item number to retrieve (1-based) */
  401.     DETItemType                        itemType;                    /*  -> Type of item to be returned (if we can interpret it as such) */
  402.     ItemRec                            item;
  403. };
  404.  
  405. typedef struct DETGetCommandItemNBlock DETGetCommandItemNBlock;
  406.  
  407. struct DETGetDSSpecBlock {
  408.     DETCallBackFunctions            reqFunction;
  409.     DETTargetSpecification            target;
  410.     PackedDSSpecPtr                    *dsSpec;                    /* <-  Handle with result (caller must DisposHandle() when done) */
  411.     short                            refNum;                        /* <-  Refnum for address if PD */
  412.     AuthIdentity                    identity;                    /* <-  Identity for address */
  413.     Boolean                            isAlias;                    /* <-  True if this entry is an alias */
  414.     Boolean                            isRecordRef;                /* <-  True if this entry is a record reference (reserved) */
  415. };
  416.  
  417. typedef struct DETGetDSSpecBlock DETGetDSSpecBlock;
  418.  
  419. struct DETGetTemplateFSSpecBlock {
  420.     DETCallBackFunctions            reqFunction;
  421.     DETTargetSpecification            target;
  422.     FSSpec                            fsSpec;                        /* <-  FSSpec of template file */
  423.     short                            baseID;                        /* <-  Base ID of this template */
  424.     long                            aspectTemplateNumber;        /* <-  The template number for this aspect template */
  425. };
  426.  
  427. typedef struct DETGetTemplateFSSpecBlock DETGetTemplateFSSpecBlock;
  428.  
  429. struct DETGetOpenEditBlock {
  430.     DETCallBackFunctions            reqFunction;
  431.     DETTargetSpecification            target;
  432.     short                            viewProperty;                /* <-  The property of the view being edited (or kNoProperty if none) */
  433. };
  434.  
  435. typedef struct DETGetOpenEditBlock DETGetOpenEditBlock;
  436.  
  437. struct DETCloseEditBlock {
  438.     DETCallBackFunctions            reqFunction;
  439.     DETTargetSpecification            target;
  440. };
  441.  
  442. typedef struct DETCloseEditBlock DETCloseEditBlock;
  443.  
  444. struct DETGetPropertyTypeBlock {
  445.     DETCallBackFunctions            reqFunction;
  446.     DETTargetSpecification            target;
  447.     short                            property;
  448.     short                            propertyType;                /* <-  The type of the property */
  449. };
  450.  
  451. typedef struct DETGetPropertyTypeBlock DETGetPropertyTypeBlock;
  452.  
  453. struct DETGetPropertyNumberBlock {
  454.     DETCallBackFunctions            reqFunction;
  455.     DETTargetSpecification            target;
  456.     short                            property;
  457.     unsigned long                    propertyValue;                /* <-  The value of the property */
  458. };
  459.  
  460. typedef struct DETGetPropertyNumberBlock DETGetPropertyNumberBlock;
  461.  
  462. struct DETGetPropertyRStringBlock {
  463.     DETCallBackFunctions            reqFunction;
  464.     DETTargetSpecification            target;
  465.     short                            property;
  466.     RStringHandle                    propertyValue;                /* <-  A handle containing the property (as an RString) (caller must DisposHandle() when done) */
  467. };
  468.  
  469. typedef struct DETGetPropertyRStringBlock DETGetPropertyRStringBlock;
  470.  
  471. struct DETGetPropertyBinarySizeBlock {
  472.     DETCallBackFunctions            reqFunction;
  473.     DETTargetSpecification            target;
  474.     short                            property;
  475.     long                            propertyBinarySize;            /* <-  The size of the property as a binary block */
  476. };
  477.  
  478. typedef struct DETGetPropertyBinarySizeBlock DETGetPropertyBinarySizeBlock;
  479.  
  480. struct DETGetPropertyBinaryBlock {
  481.     DETCallBackFunctions            reqFunction;
  482.     DETTargetSpecification            target;
  483.     short                            property;
  484.     Handle                            propertyValue;                /* <-  Handle with the value of the property (caller must DisposHandle() when done) */
  485. };
  486.  
  487. typedef struct DETGetPropertyBinaryBlock DETGetPropertyBinaryBlock;
  488.  
  489. struct DETGetPropertyChangedBlock {
  490.     DETCallBackFunctions            reqFunction;
  491.     DETTargetSpecification            target;
  492.     short                            property;
  493.     Boolean                            propertyChanged;            /* <-  True if the property is marked as changed */
  494.     Boolean                            filler1;
  495. };
  496.  
  497. typedef struct DETGetPropertyChangedBlock DETGetPropertyChangedBlock;
  498.  
  499. struct DETGetPropertyEditableBlock {
  500.     DETCallBackFunctions            reqFunction;
  501.     DETTargetSpecification            target;
  502.     short                            property;
  503.     Boolean                            propertyEditable;            /* <-  True if the property can be edited by the user (if false, view will appear disabled) */
  504.     Boolean                            filler1;
  505. };
  506.  
  507. typedef struct DETGetPropertyEditableBlock DETGetPropertyEditableBlock;
  508.  
  509. struct DETSetPropertyTypeBlock {
  510.     DETCallBackFunctions            reqFunction;
  511.     DETTargetSpecification            target;
  512.     short                            property;
  513.     short                            newType;                    /*  -> New type for property (just sets type, does not convert contents) */
  514. };
  515.  
  516. typedef struct DETSetPropertyTypeBlock DETSetPropertyTypeBlock;
  517.  
  518. struct DETSetPropertyNumberBlock {
  519.     DETCallBackFunctions            reqFunction;
  520.     DETTargetSpecification            target;
  521.     short                            property;
  522.     unsigned long                    newValue;                    /*  -> New value to set property to (and set type to number) */
  523. };
  524.  
  525. typedef struct DETSetPropertyNumberBlock DETSetPropertyNumberBlock;
  526.  
  527. struct DETSetPropertyRStringBlock {
  528.     DETCallBackFunctions            reqFunction;
  529.     DETTargetSpecification            target;
  530.     short                            property;
  531.     RStringPtr                        newValue;                    /*  -> New value to set property to (and set type to RString) */
  532. };
  533.  
  534. typedef struct DETSetPropertyRStringBlock DETSetPropertyRStringBlock;
  535.  
  536. struct DETSetPropertyBinaryBlock {
  537.     DETCallBackFunctions            reqFunction;
  538.     DETTargetSpecification            target;
  539.     short                            property;
  540.     Ptr                                newValue;                    /*  -> New value to set property to (and set type to binary) */
  541.     long                            newValueSize;                /*  -> Size of new value */
  542. };
  543.  
  544. typedef struct DETSetPropertyBinaryBlock DETSetPropertyBinaryBlock;
  545.  
  546. struct DETSetPropertyChangedBlock {
  547.     DETCallBackFunctions            reqFunction;
  548.     DETTargetSpecification            target;
  549.     short                            property;
  550.     Boolean                            propertyChanged;            /*  -> Value to set changed flag on property to */
  551.     Boolean                            filler1;
  552. };
  553.  
  554. typedef struct DETSetPropertyChangedBlock DETSetPropertyChangedBlock;
  555.  
  556. struct DETSetPropertyEditableBlock {
  557.     DETCallBackFunctions            reqFunction;
  558.     DETTargetSpecification            target;
  559.     short                            property;
  560.     Boolean                            propertyEditable;            /*  -> Value to set editable flag on property to */
  561.     Boolean                            filler1;
  562. };
  563.  
  564. typedef struct DETSetPropertyEditableBlock DETSetPropertyEditableBlock;
  565.  
  566. struct DETDirtyPropertyBlock {
  567.     DETCallBackFunctions            reqFunction;
  568.     DETTargetSpecification            target;
  569.     short                            property;
  570. };
  571.  
  572. typedef struct DETDirtyPropertyBlock DETDirtyPropertyBlock;
  573.  
  574. struct DETDoPropertyCommandBlock {
  575.     DETCallBackFunctions            reqFunction;
  576.     DETTargetSpecification            target;
  577.     short                            property;
  578.     long                            parameter;                    /* ->  Parameter of command */
  579. };
  580.  
  581. typedef struct DETDoPropertyCommandBlock DETDoPropertyCommandBlock;
  582.  
  583. struct DETSublistCountBlock {
  584.     DETCallBackFunctions            reqFunction;
  585.     DETTargetSpecification            target;
  586.     long                            count;                        /* <-  The number of items in the current item's sublist */
  587. };
  588.  
  589. typedef struct DETSublistCountBlock DETSublistCountBlock;
  590.  
  591. struct DETSelectedSublistCountBlock {
  592.     DETCallBackFunctions            reqFunction;
  593.     DETTargetSpecification            target;
  594.     long                            count;                        /* <-  The number of selected items in the current item's sublist */
  595. };
  596.  
  597. typedef struct DETSelectedSublistCountBlock DETSelectedSublistCountBlock;
  598.  
  599. struct DETRequestSyncBlock {
  600.     DETCallBackFunctions            reqFunction;
  601.     DETTargetSpecification            target;
  602. };
  603.  
  604. typedef struct DETRequestSyncBlock DETRequestSyncBlock;
  605.  
  606. struct DETAddMenuBlock {
  607.     DETCallBackFunctions            reqFunction;
  608.     DETTargetSpecification            target;
  609.     short                            property;
  610.     RString                            *name;                        /*  -> Name of new menu item */
  611.     long                            parameter;                    /*  -> Parameter to return when this item is selected */
  612.     long                            addAfter;                    /*  -> Parameter of entry to add after, or -1 for add at end */
  613. };
  614.  
  615. typedef struct DETAddMenuBlock DETAddMenuBlock;
  616.  
  617. struct DETRemoveMenuBlock {
  618.     DETCallBackFunctions            reqFunction;
  619.     DETTargetSpecification            target;
  620.     short                            property;
  621.     long                            itemToRemove;                /*  -> Parameter of menu item to remove */
  622. };
  623.  
  624. typedef struct DETRemoveMenuBlock DETRemoveMenuBlock;
  625.  
  626. struct DETMenuItemRStringBlock {
  627.     DETCallBackFunctions            reqFunction;
  628.     DETTargetSpecification            target;
  629.     short                            property;
  630.     long                            itemParameter;                /*  -> Parameter of menu item to return string for */
  631.     RStringHandle                    rString;                    /* <-  Handle with the RString (caller must DisposHandle() when done) */
  632. };
  633.  
  634. typedef struct DETMenuItemRStringBlock DETMenuItemRStringBlock;
  635.  
  636. struct DETOpenDSSpecBlock {
  637.     DETCallBackFunctions            reqFunction;
  638.     PackedDSSpecPtr                    dsSpec;                        /*  -> DSSpec of object to be opened */
  639. };
  640.  
  641. typedef struct DETOpenDSSpecBlock DETOpenDSSpecBlock;
  642.  
  643. struct DETAboutToTalkBlock {
  644.     DETCallBackFunctions            reqFunction;
  645. };
  646.  
  647. typedef struct DETAboutToTalkBlock DETAboutToTalkBlock;
  648.  
  649. struct DETBreakAttributeBlock {
  650.     DETCallBackFunctions            reqFunction;
  651.     DETTargetSpecification            target;
  652.     AttributePtr                    breakAttribute;                /*  -> Attribute to parse */
  653.     Boolean                            isChangeable;                /*  -> True if the value can be changed by the user */
  654.     Boolean                            filler1;
  655. };
  656.  
  657. typedef struct DETBreakAttributeBlock DETBreakAttributeBlock;
  658.  
  659. struct DETSavePropertyBlock {
  660.     DETCallBackFunctions            reqFunction;
  661.     DETTargetSpecification            target;
  662.     short                            property;
  663. };
  664.  
  665. typedef struct DETSavePropertyBlock DETSavePropertyBlock;
  666.  
  667. struct DETGetCustomViewUserReferenceBlock {
  668.     DETCallBackFunctions            reqFunction;
  669.     DETTargetSpecification            target;
  670.     short                            property;
  671.     short                            userReference;                /* <-  User reference value, as specified in the .r file */
  672. };
  673.  
  674. typedef struct DETGetCustomViewUserReferenceBlock DETGetCustomViewUserReferenceBlock;
  675.  
  676. struct DETGetCustomViewBoundsBlock {
  677.     DETCallBackFunctions            reqFunction;
  678.     DETTargetSpecification            target;
  679.     short                            property;
  680.     Rect                            bounds;                        /* <-  Bounds of the view */
  681. };
  682.  
  683. typedef struct DETGetCustomViewBoundsBlock DETGetCustomViewBoundsBlock;
  684.  
  685. struct DETGetResourceBlock {
  686.     DETCallBackFunctions            reqFunction;
  687.     DETTargetSpecification            target;
  688.     short                            property;
  689.     ResType                            resourceType;                /*  -> Resource type */
  690.     Handle                            theResource;                /* <-  The resource handle (caller must dispose when done) */
  691. };
  692.  
  693. typedef struct DETGetResourceBlock DETGetResourceBlock;
  694.  
  695. struct DETTemplateCounts {
  696.     DETCallBackFunctions            reqFunction;
  697.     long                            aspectTemplateCount;        /* <-  Number of aspect templates in the system */
  698.     long                            infoPageTemplateCount;        /* <-  Number of info-page templates in the system */
  699. };
  700.  
  701. typedef struct DETTemplateCounts DETTemplateCounts;
  702.  
  703. struct DETUnloadTemplatesBlock {
  704.     DETCallBackFunctions            reqFunction;
  705. };
  706.  
  707. typedef struct DETUnloadTemplatesBlock DETUnloadTemplatesBlock;
  708.  
  709. union DETCallBackBlock {
  710.     DETProtoCallBackBlock            protoCallBack;
  711.     DETBeepBlock                    beep;
  712.     DETBusyBlock                    busy;
  713.     DETChangeCallForsBlock            changeCallFors;
  714.     DETGetCommandSelectionCountBlock getCommandSelectionCount;
  715.     DETGetCommandItemNBlock            getCommandItemN;
  716.     DETGetDSSpecBlock                getDSSpec;
  717.     DETGetTemplateFSSpecBlock        getTemplateFSSpec;
  718.     DETGetOpenEditBlock                getOpenEdit;
  719.     DETCloseEditBlock                closeEdit;
  720.     DETGetPropertyTypeBlock            getPropertyType;
  721.     DETGetPropertyNumberBlock        getPropertyNumber;
  722.     DETGetPropertyRStringBlock        getPropertyRString;
  723.     DETGetPropertyBinarySizeBlock    getPropertyBinarySize;
  724.     DETGetPropertyBinaryBlock        getPropertyBinary;
  725.     DETGetPropertyChangedBlock        getPropertyChanged;
  726.     DETGetPropertyEditableBlock        getPropertyEditable;
  727.     DETSetPropertyTypeBlock            setPropertyType;
  728.     DETSetPropertyNumberBlock        setPropertyNumber;
  729.     DETSetPropertyRStringBlock        setPropertyRString;
  730.     DETSetPropertyBinaryBlock        setPropertyBinary;
  731.     DETSetPropertyChangedBlock        setPropertyChanged;
  732.     DETSetPropertyEditableBlock        setPropertyEditable;
  733.     DETDirtyPropertyBlock            dirtyProperty;
  734.     DETDoPropertyCommandBlock        doPropertyCommand;
  735.     DETSublistCountBlock            sublistCount;
  736.     DETSelectedSublistCountBlock    selectedSublistCount;
  737.     DETRequestSyncBlock                requestSync;
  738.     DETAddMenuBlock                    addMenu;
  739.     DETRemoveMenuBlock                removeMenu;
  740.     DETMenuItemRStringBlock            menuItemRString;
  741.     DETOpenDSSpecBlock                openDSSpec;
  742.     DETAboutToTalkBlock                aboutToTalk;
  743.     DETBreakAttributeBlock            breakAttribute;
  744.     DETSavePropertyBlock            saveProperty;
  745.     DETGetCustomViewUserReferenceBlock getCustomViewUserReference;
  746.     DETGetCustomViewBoundsBlock        getCustomViewBounds;
  747.     DETGetResourceBlock                getResource;
  748.     DETTemplateCounts                templateCounts;
  749.     DETUnloadTemplatesBlock            unloadTemplates;
  750. };
  751. typedef union DETCallBackBlock DETCallBackBlock;
  752.  
  753. typedef DETCallBackBlock *DETCallBackBlockPtr;
  754.  
  755. typedef pascal OSErr (*DETCallBackProcPtr)(union DETCallBlock *callBlockPtr, DETCallBackBlockPtr callBackBlockPtr);
  756.  
  757. #if GENERATINGCFM
  758. typedef UniversalProcPtr DETCallBackUPP;
  759. #else
  760. typedef DETCallBackProcPtr DETCallBackUPP;
  761. #endif
  762.  
  763. typedef DETCallBackUPP DETCallBack;
  764.  
  765. /* Call functions:
  766.  
  767.         reqFunction                        Action
  768.         -----------                        ------
  769.         kDETcmdInit                        Called once when template is first loaded (good time to allocate private data); returns call-for list
  770.         kDETcmdExit                        Called once when template is freed (good time to free private data)
  771.  
  772.         kDETcmdAttributeCreation        New sublist attribute creation about to occur; this gives the template a chance to modify
  773.                                         the value that's about to be created; sent to the template that will be used for
  774.                                         the main aspect of the new entry
  775.  
  776.         kDETcmdDynamicForwarders        Return a list of dynamically created forwarders
  777.  
  778.         kDETcmdInstanceInit                Called once when instance of template is started (good time to allocate private instance data)
  779.         kDETcmdInstanceExit                Called once when instance is ended (good time to free private instance data)
  780.  
  781.         kDETcmdIdle                        Called periodically during idle times
  782.  
  783.         kDETcmdViewListChanged            Called when the info-page view-list (list of enabled views) has changed
  784.  
  785.         kDETcmdValidateSave                Validate save: about to save info-page, return noErr (or kDETDidNotHandle) if it's OK to do so
  786.  
  787.         kDETcmdDropQuery                Drop query: return the appropriate operation for this drag; ask destination
  788.         kDETcmdDropMeQuery                Drop query: return the appropriate operation for this drag; ask dropee
  789.  
  790.         kDETcmdAttributeNew                Attribute value new (return kDETDidNotHandle to let normal new processing occur)
  791.         kDETcmdAttributeChange            Attribute value change (return kDETDidNotHandle to let normal change processing occur)
  792.         kDETcmdAttributeDelete            Attribute value delete (return kDETDidNotHandle to let normal deletion occur); sent to the
  793.                                         main aspect of the attribute that's about to be deleted
  794.         kDETcmdItemNew                    Target item (record or attribute) has just been created
  795.  
  796.         kDETcmdOpenSelf                    Self open (return noErr to prevent opening; return kDETDidNotHandle to allow it)
  797.  
  798.         kDETcmdDynamicResource            Return a dynamically created resource
  799.  
  800.         kDETcmdShouldSync                Check if the code resource wants to force a sync (update data from catalog)
  801.         kDETcmdDoSync                    Give code resource a chance to sync (read in and break all attributes)
  802.  
  803.         kDETcmdPropertyCommand            Command received in the property number range (usually means a button's been pushed)
  804.  
  805.         kDETcmdMaximumTextLength        Return maximum size for text form of property
  806.  
  807.         kDETcmdPropertyDirtied            Property dirtied, need to redraw
  808.  
  809.         kDETcmdPatternIn                Custom pattern element encountered on reading in an attribute
  810.         kDETcmdPatternOut                Custom pattern element encountered on writing out an attribute
  811.  
  812.         kDETcmdConvertToNumber            Convert from template-defined property type to number
  813.         kDETcmdConvertToRString            Convert from template-defined property type to RString
  814.         kDETcmdConvertFromNumber        Convert from number to template-defined property type
  815.         kDETcmdConvertFromRString        Convert from RString to template-defined property type
  816.  
  817.         kDETcmdCustomViewDraw            Custom view draw
  818.         kDETcmdCustomViewMouseDown        Custom view mouse down
  819.  
  820.         kDETcmdKeyPress                    Key press (used primarily to filter entry into EditText views)
  821.         kDETcmdPaste                    Paste (used primarily to filter entry into EditText views)
  822.  
  823.         kDETcmdCustomMenuSelected        Custom Catalogs menu selected
  824.         kDETcmdCustomMenuEnabled        Return whether custom Catalogs menu entry should be enabled
  825. */
  826.  
  827. enum {
  828.     kDETcmdSimpleCall            = 0,
  829.     kDETcmdInit,
  830.     kDETcmdExit,
  831.     kDETcmdAttributeCreation,
  832.     kDETcmdDynamicForwarders,
  833.     kDETcmdTargetedCall            = 1000,
  834.     kDETcmdInstanceInit,
  835.     kDETcmdInstanceExit,
  836.     kDETcmdIdle,
  837.     kDETcmdViewListChanged,
  838.     kDETcmdValidateSave,
  839.     kDETcmdDropQuery,
  840.     kDETcmdDropMeQuery,
  841.     kDETcmdAttributeNew,
  842.     kDETcmdAttributeChange,
  843.     kDETcmdAttributeDelete,
  844.     kDETcmdItemNew,
  845.     kDETcmdOpenSelf,
  846.     kDETcmdDynamicResource,
  847.     kDETcmdShouldSync,
  848.     kDETcmdDoSync,
  849.     kDETcmdPropertyCall            = 2000,
  850.     kDETcmdPropertyCommand,
  851.     kDETcmdMaximumTextLength,
  852.     kDETcmdPropertyDirtied,
  853.     kDETcmdPatternIn,
  854.     kDETcmdPatternOut,
  855.     kDETcmdConvertToNumber,
  856.     kDETcmdConvertToRString,
  857.     kDETcmdConvertFromNumber,
  858.     kDETcmdConvertFromRString,
  859.     kDETcmdCustomViewDraw,
  860.     kDETcmdCustomViewMouseDown,
  861.     kDETcmdKeyPress,
  862.     kDETcmdPaste,
  863.     kDETcmdCustomMenuSelected,
  864.     kDETcmdCustomMenuEnabled,
  865.     kDETcmdHighCall                = 0xF0000000                    /* Force the type to be long */
  866. };
  867.  
  868. typedef unsigned long DETCallFunctions;
  869.  
  870. #define DETCallBlockHeader         \
  871.     DETCallFunctions reqFunction;     \
  872.     DETCallBack callBack;            \
  873.     long callBackPrivate;            \
  874.     long templatePrivate;
  875. #define DETCallBlockTargetedHeader  \
  876.     DETCallFunctions reqFunction;     \
  877.     DETCallBack callBack;            \
  878.     long callBackPrivate;            \
  879.     long templatePrivate;            \
  880.     long instancePrivate;            \
  881.     DETTargetSpecification target;     \
  882.     Boolean targetIsMainAspect;     \
  883.     Boolean filler1;
  884. #define DETCallBlockPropertyHeader  \
  885.     DETCallFunctions reqFunction;     \
  886.     DETCallBack callBack;            \
  887.     long callBackPrivate;            \
  888.     long templatePrivate;            \
  889.     long instancePrivate;            \
  890.     DETTargetSpecification target;     \
  891.     Boolean targetIsMainAspect;     \
  892.     Boolean filler1;             \
  893.     short property;
  894. struct DETProtoCallBlock {
  895.     DETCallFunctions                reqFunction;
  896.     DETCallBack                        callBack;
  897.     long                            callBackPrivate;
  898.     long                            templatePrivate;
  899.     long                            instancePrivate;
  900.     DETTargetSpecification            target;
  901.     Boolean                            targetIsMainAspect;
  902.     Boolean                            filler1;
  903.     short                            property;
  904. };
  905.  
  906. typedef struct DETProtoCallBlock DETProtoCallBlock;
  907.  
  908. struct DETInitBlock {
  909.     DETCallFunctions                reqFunction;
  910.     DETCallBack                        callBack;
  911.     long                            callBackPrivate;
  912.     long                            templatePrivate;
  913.     long                            newCallFors;                /* <-  New call-for mask */
  914. };
  915.  
  916. typedef struct DETInitBlock DETInitBlock;
  917.  
  918. struct DETExitBlock {
  919.     DETCallFunctions                reqFunction;
  920.     DETCallBack                        callBack;
  921.     long                            callBackPrivate;
  922.     long                            templatePrivate;
  923. };
  924.  
  925. typedef struct DETExitBlock DETExitBlock;
  926.  
  927. struct DETInstanceInitBlock {
  928.     DETCallFunctions                reqFunction;
  929.     DETCallBack                        callBack;
  930.     long                            callBackPrivate;
  931.     long                            templatePrivate;
  932.     long                            instancePrivate;
  933.     DETTargetSpecification            target;
  934.     Boolean                            targetIsMainAspect;
  935.     Boolean                            filler1;
  936. };
  937.  
  938. typedef struct DETInstanceInitBlock DETInstanceInitBlock;
  939.  
  940. struct DETInstanceExitBlock {
  941.     DETCallFunctions                reqFunction;
  942.     DETCallBack                        callBack;
  943.     long                            callBackPrivate;
  944.     long                            templatePrivate;
  945.     long                            instancePrivate;
  946.     DETTargetSpecification            target;
  947.     Boolean                            targetIsMainAspect;
  948.     Boolean                            filler1;
  949. };
  950.  
  951. typedef struct DETInstanceExitBlock DETInstanceExitBlock;
  952.  
  953. struct DETInstanceIdleBlock {
  954.     DETCallFunctions                reqFunction;
  955.     DETCallBack                        callBack;
  956.     long                            callBackPrivate;
  957.     long                            templatePrivate;
  958.     long                            instancePrivate;
  959.     DETTargetSpecification            target;
  960.     Boolean                            targetIsMainAspect;
  961.     Boolean                            filler1;
  962. };
  963.  
  964. typedef struct DETInstanceIdleBlock DETInstanceIdleBlock;
  965.  
  966. struct DETPropertyCommandBlock {
  967.     DETCallFunctions                reqFunction;
  968.     DETCallBack                        callBack;
  969.     long                            callBackPrivate;
  970.     long                            templatePrivate;
  971.     long                            instancePrivate;
  972.     DETTargetSpecification            target;
  973.     Boolean                            targetIsMainAspect;
  974.     Boolean                            filler1;
  975.     short                            property;
  976.     long                            parameter;                    /*  -> Parameter of command */
  977. };
  978.  
  979. typedef struct DETPropertyCommandBlock DETPropertyCommandBlock;
  980.  
  981. struct DETMaximumTextLengthBlock {
  982.     DETCallFunctions                reqFunction;
  983.     DETCallBack                        callBack;
  984.     long                            callBackPrivate;
  985.     long                            templatePrivate;
  986.     long                            instancePrivate;
  987.     DETTargetSpecification            target;
  988.     Boolean                            targetIsMainAspect;
  989.     Boolean                            filler1;
  990.     short                            property;
  991.     long                            maxSize;                    /* <-  Return the maximum number of characters the user can entry when property is edited in an EditText */
  992. };
  993.  
  994. typedef struct DETMaximumTextLengthBlock DETMaximumTextLengthBlock;
  995.  
  996. struct DETViewListChangedBlock {
  997.     DETCallFunctions                reqFunction;
  998.     DETCallBack                        callBack;
  999.     long                            callBackPrivate;
  1000.     long                            templatePrivate;
  1001.     long                            instancePrivate;
  1002.     DETTargetSpecification            target;
  1003.     Boolean                            targetIsMainAspect;
  1004.     Boolean                            filler1;
  1005. };
  1006.  
  1007. typedef struct DETViewListChangedBlock DETViewListChangedBlock;
  1008.  
  1009. struct DETPropertyDirtiedBlock {
  1010.     DETCallFunctions                reqFunction;
  1011.     DETCallBack                        callBack;
  1012.     long                            callBackPrivate;
  1013.     long                            templatePrivate;
  1014.     long                            instancePrivate;
  1015.     DETTargetSpecification            target;
  1016.     Boolean                            targetIsMainAspect;
  1017.     Boolean                            filler1;
  1018.     short                            property;
  1019. };
  1020.  
  1021. typedef struct DETPropertyDirtiedBlock DETPropertyDirtiedBlock;
  1022.  
  1023. struct DETValidateSaveBlock {
  1024.     DETCallFunctions                reqFunction;
  1025.     DETCallBack                        callBack;
  1026.     long                            callBackPrivate;
  1027.     long                            templatePrivate;
  1028.     long                            instancePrivate;
  1029.     DETTargetSpecification            target;
  1030.     Boolean                            targetIsMainAspect;
  1031.     Boolean                            filler1;
  1032.     RStringHandle                    errorString;                /* <-  Handle with error string if validation fails (callee must allocate handle, DE will DisposHandle() it) */
  1033. };
  1034.  
  1035. typedef struct DETValidateSaveBlock DETValidateSaveBlock;
  1036.  
  1037. /* Valid commandIDs for DETDropQueryBlock and DETDropMeQueryBlock (in addition to property numbers): */
  1038.  
  1039. enum {
  1040.     kDETDoNothing                = 'xxx0',
  1041.     kDETMove                    = 'move',
  1042.     kDETDrag                    = 'drag',
  1043.     kDETAlias                    = 'alis'
  1044. };
  1045.  
  1046. struct DETDropQueryBlock {
  1047.     DETCallFunctions                reqFunction;
  1048.     DETCallBack                        callBack;
  1049.     long                            callBackPrivate;
  1050.     long                            templatePrivate;
  1051.     long                            instancePrivate;
  1052.     DETTargetSpecification            target;
  1053.     Boolean                            targetIsMainAspect;
  1054.     Boolean                            filler1;
  1055.     short                            modifiers;                    /*  -> Modifiers at drop time (option/control/command/shift keys) */
  1056.     long                            commandID;                    /* <-> Command ID (kDETDoNothing, kDETMove, kDETDrag (copy), kDETAlias, or a property number) */
  1057.     AttributeType                    destinationType;            /* <-> Type to convert attribute to */
  1058.     Boolean                            copyToHFS;                    /* <-  If true, object should be copied to HFS before being operated on, and deleted after */
  1059.     Boolean                            filler2;
  1060. };
  1061.  
  1062. typedef struct DETDropQueryBlock DETDropQueryBlock;
  1063.  
  1064. struct DETDropMeQueryBlock {
  1065.     DETCallFunctions                reqFunction;
  1066.     DETCallBack                        callBack;
  1067.     long                            callBackPrivate;
  1068.     long                            templatePrivate;
  1069.     long                            instancePrivate;
  1070.     DETTargetSpecification            target;
  1071.     Boolean                            targetIsMainAspect;
  1072.     Boolean                            filler1;
  1073.     short                            modifiers;                    /*  -> Modifiers at drop time (option/control/command/shift keys) */
  1074.     long                            commandID;                    /* <-> Command ID (kDETDoNothing, kDETMove, kDETDrag (copy), kDETAlias, or a property number) */
  1075.     AttributeType                    destinationType;            /* <-> Type to convert attribute to */
  1076.     Boolean                            copyToHFS;                    /* <-  If true, object should be copied to HFS before being operated on, and deleted after */
  1077.     Boolean                            filler2;
  1078. };
  1079.  
  1080. typedef struct DETDropMeQueryBlock DETDropMeQueryBlock;
  1081.  
  1082. struct DETAttributeCreationBlock {
  1083.     DETCallFunctions                reqFunction;
  1084.     DETCallBack                        callBack;
  1085.     long                            callBackPrivate;
  1086.     long                            templatePrivate;
  1087.     PackedDSSpecPtr                    parent;                        /*  -> The object within which the creation will occur */
  1088.     short                            refNum;                        /*  -> Refnum for returned address (DSSpecs in PDs only) */
  1089.     AuthIdentity                    identity;                    /*  -> The identity we're browsing as in the parent object */
  1090.     AttributeType                    attrType;                    /* <-> The type of the attribute being created */
  1091.     AttributeTag                    attrTag;                    /* <-> The tag of the attribute being created */
  1092.     Handle                            value;                        /* <-> The value to write (pre-allocated, resize as needed) */
  1093. };
  1094.  
  1095. typedef struct DETAttributeCreationBlock DETAttributeCreationBlock;
  1096.  
  1097. struct DETAttributeNewBlock {
  1098.     DETCallFunctions                reqFunction;
  1099.     DETCallBack                        callBack;
  1100.     long                            callBackPrivate;
  1101.     long                            templatePrivate;
  1102.     long                            instancePrivate;
  1103.     DETTargetSpecification            target;
  1104.     Boolean                            targetIsMainAspect;
  1105.     Boolean                            filler1;
  1106.     PackedDSSpecPtr                    parent;                        /*  -> The object within which the creation will occur */
  1107.     short                            refNum;                        /*  -> Refnum for returned address (DSSpecs in PDs only) */
  1108.     AuthIdentity                    identity;                    /*  -> The identity we're browsing as in the parent object */
  1109.     AttributeType                    attrType;                    /* <-> The type of the attribute being created */
  1110.     AttributeTag                    attrTag;                    /* <-> The tag of the attribute being created */
  1111.     Handle                            value;                        /* <-> The value to write (pre-allocated, resize as needed) */
  1112. };
  1113.  
  1114. typedef struct DETAttributeNewBlock DETAttributeNewBlock;
  1115.  
  1116. struct DETAttributeChangeBlock {
  1117.     DETCallFunctions                reqFunction;
  1118.     DETCallBack                        callBack;
  1119.     long                            callBackPrivate;
  1120.     long                            templatePrivate;
  1121.     long                            instancePrivate;
  1122.     DETTargetSpecification            target;
  1123.     Boolean                            targetIsMainAspect;
  1124.     Boolean                            filler1;
  1125.     PackedDSSpecPtr                    parent;                        /*  -> The object within which the creation will occur */
  1126.     short                            refNum;                        /*  -> Refnum for returned address (DSSpecs in PDs only) */
  1127.     AuthIdentity                    identity;                    /*  -> The identity we're browsing as in the parent object */
  1128.     AttributeType                    attrType;                    /* <-> The type of the attribute being changed */
  1129.     AttributeTag                    attrTag;                    /* <-> The tag of the attribute being changed */
  1130.     AttributeCreationID                attrCID;                    /* <-> The CID of the attribute being changed */
  1131.     Handle                            value;                        /* <-> The value to write (pre-allocated, resize as needed) */
  1132. };
  1133.  
  1134. typedef struct DETAttributeChangeBlock DETAttributeChangeBlock;
  1135.  
  1136. struct DETAttributeDeleteBlock {
  1137.     DETCallFunctions                reqFunction;
  1138.     DETCallBack                        callBack;
  1139.     long                            callBackPrivate;
  1140.     long                            templatePrivate;
  1141.     long                            instancePrivate;
  1142.     DETTargetSpecification            target;
  1143.     Boolean                            targetIsMainAspect;
  1144.     Boolean                            filler1;
  1145.     PackedDSSpecPtr                    dsSpec;                        /*  -> The object which will be deleted */
  1146.     short                            refNum;                        /*  -> Refnum for returned address (DSSpecs in PDs only) */
  1147.     AuthIdentity                    identity;                    /*  -> The identity we're browsing as */
  1148. };
  1149.  
  1150. typedef struct DETAttributeDeleteBlock DETAttributeDeleteBlock;
  1151.  
  1152. struct DETItemNewBlock {
  1153.     DETCallFunctions                reqFunction;
  1154.     DETCallBack                        callBack;
  1155.     long                            callBackPrivate;
  1156.     long                            templatePrivate;
  1157.     long                            instancePrivate;
  1158.     DETTargetSpecification            target;
  1159.     Boolean                            targetIsMainAspect;
  1160.     Boolean                            filler1;
  1161. };
  1162.  
  1163. typedef struct DETItemNewBlock DETItemNewBlock;
  1164.  
  1165. struct DETShouldSyncBlock {
  1166.     DETCallFunctions                reqFunction;
  1167.     DETCallBack                        callBack;
  1168.     long                            callBackPrivate;
  1169.     long                            templatePrivate;
  1170.     long                            instancePrivate;
  1171.     DETTargetSpecification            target;
  1172.     Boolean                            targetIsMainAspect;
  1173.     Boolean                            filler1;
  1174.     Boolean                            shouldSync;                    /* <-  True if we should now sync with catalog */
  1175.     Boolean                            filler2;
  1176. };
  1177.  
  1178. typedef struct DETShouldSyncBlock DETShouldSyncBlock;
  1179.  
  1180. struct DETDoSyncBlock {
  1181.     DETCallFunctions                reqFunction;
  1182.     DETCallBack                        callBack;
  1183.     long                            callBackPrivate;
  1184.     long                            templatePrivate;
  1185.     long                            instancePrivate;
  1186.     DETTargetSpecification            target;
  1187.     Boolean                            targetIsMainAspect;
  1188.     Boolean                            filler1;
  1189. };
  1190.  
  1191. typedef struct DETDoSyncBlock DETDoSyncBlock;
  1192.  
  1193. struct DETPatternInBlock {
  1194.     DETCallFunctions                reqFunction;
  1195.     DETCallBack                        callBack;
  1196.     long                            callBackPrivate;
  1197.     long                            templatePrivate;
  1198.     long                            instancePrivate;
  1199.     DETTargetSpecification            target;
  1200.     Boolean                            targetIsMainAspect;
  1201.     Boolean                            filler1;
  1202.     short                            property;
  1203.     long                            elementType;                /*  -> Element type from pattern */
  1204.     long                            extra;                        /*  -> Extra field from pattern */
  1205.     AttributePtr                    attribute;                    /*  -> The complete attribute */
  1206.     long                            dataOffset;                    /* <-> Offset to current (next) byte */
  1207.     short                            bitOffset;                    /* <-> Bit offset (next bit is *fData >> fBitOffset++) */
  1208. };
  1209.  
  1210. typedef struct DETPatternInBlock DETPatternInBlock;
  1211.  
  1212. struct DETPatternOutBlock {
  1213.     DETCallFunctions                reqFunction;
  1214.     DETCallBack                        callBack;
  1215.     long                            callBackPrivate;
  1216.     long                            templatePrivate;
  1217.     long                            instancePrivate;
  1218.     DETTargetSpecification            target;
  1219.     Boolean                            targetIsMainAspect;
  1220.     Boolean                            filler1;
  1221.     short                            property;
  1222.     long                            elementType;                /*  -> Element type from pattern */
  1223.     long                            extra;                        /*  -> Extra field from pattern */
  1224.     AttributePtr                    attribute;                    /*  -> The attribute (minus the data portion) */
  1225.     Handle                            data;                        /*  -> Data to be written (pre-allocated, resize and add at end) */
  1226.     long                            dataOffset;                    /* <-> Offset to next byte to write */
  1227.     short                            bitOffset;                    /* <-> Bit offset (if zero, handle will need to be resized to one more byte before write) */
  1228. };
  1229.  
  1230. typedef struct DETPatternOutBlock DETPatternOutBlock;
  1231.  
  1232. struct DETOpenSelfBlock {
  1233.     DETCallFunctions                reqFunction;
  1234.     DETCallBack                        callBack;
  1235.     long                            callBackPrivate;
  1236.     long                            templatePrivate;
  1237.     long                            instancePrivate;
  1238.     DETTargetSpecification            target;
  1239.     Boolean                            targetIsMainAspect;
  1240.     Boolean                            filler1;
  1241.     short                            modifiers;                    /*  -> Modifiers at open time (option/control/command/shift keys) */
  1242. };
  1243.  
  1244. typedef struct DETOpenSelfBlock DETOpenSelfBlock;
  1245.  
  1246. struct DETConvertToNumberBlock {
  1247.     DETCallFunctions                reqFunction;
  1248.     DETCallBack                        callBack;
  1249.     long                            callBackPrivate;
  1250.     long                            templatePrivate;
  1251.     long                            instancePrivate;
  1252.     DETTargetSpecification            target;
  1253.     Boolean                            targetIsMainAspect;
  1254.     Boolean                            filler1;
  1255.     short                            property;
  1256.     long                            theValue;                    /* <-  The converted value to return */
  1257. };
  1258.  
  1259. typedef struct DETConvertToNumberBlock DETConvertToNumberBlock;
  1260.  
  1261. struct DETConvertToRStringBlock {
  1262.     DETCallFunctions                reqFunction;
  1263.     DETCallBack                        callBack;
  1264.     long                            callBackPrivate;
  1265.     long                            templatePrivate;
  1266.     long                            instancePrivate;
  1267.     DETTargetSpecification            target;
  1268.     Boolean                            targetIsMainAspect;
  1269.     Boolean                            filler1;
  1270.     short                            property;
  1271.     RStringHandle                    theValue;                    /* <-  A handle with the converted value (callee must allocate handle, DE will DisposHandle() it) */
  1272. };
  1273.  
  1274. typedef struct DETConvertToRStringBlock DETConvertToRStringBlock;
  1275.  
  1276. struct DETConvertFromNumberBlock {
  1277.     DETCallFunctions                reqFunction;
  1278.     DETCallBack                        callBack;
  1279.     long                            callBackPrivate;
  1280.     long                            templatePrivate;
  1281.     long                            instancePrivate;
  1282.     DETTargetSpecification            target;
  1283.     Boolean                            targetIsMainAspect;
  1284.     Boolean                            filler1;
  1285.     short                            property;
  1286.     long                            theValue;                    /*  -> The value to convert (result should be written direct to the property) */
  1287. };
  1288.  
  1289. typedef struct DETConvertFromNumberBlock DETConvertFromNumberBlock;
  1290.  
  1291. struct DETConvertFromRStringBlock {
  1292.     DETCallFunctions                reqFunction;
  1293.     DETCallBack                        callBack;
  1294.     long                            callBackPrivate;
  1295.     long                            templatePrivate;
  1296.     long                            instancePrivate;
  1297.     DETTargetSpecification            target;
  1298.     Boolean                            targetIsMainAspect;
  1299.     Boolean                            filler1;
  1300.     short                            property;
  1301.     RStringPtr                        theValue;                    /*  -> The value to convert (result should be written direct to the property) */
  1302. };
  1303.  
  1304. typedef struct DETConvertFromRStringBlock DETConvertFromRStringBlock;
  1305.  
  1306. struct DETCustomViewDrawBlock {
  1307.     DETCallFunctions                reqFunction;
  1308.     DETCallBack                        callBack;
  1309.     long                            callBackPrivate;
  1310.     long                            templatePrivate;
  1311.     long                            instancePrivate;
  1312.     DETTargetSpecification            target;
  1313.     Boolean                            targetIsMainAspect;
  1314.     Boolean                            filler1;
  1315.     short                            property;
  1316. };
  1317.  
  1318. typedef struct DETCustomViewDrawBlock DETCustomViewDrawBlock;
  1319.  
  1320. struct DETCustomViewMouseDownBlock {
  1321.     DETCallFunctions                reqFunction;
  1322.     DETCallBack                        callBack;
  1323.     long                            callBackPrivate;
  1324.     long                            templatePrivate;
  1325.     long                            instancePrivate;
  1326.     DETTargetSpecification            target;
  1327.     Boolean                            targetIsMainAspect;
  1328.     Boolean                            filler1;
  1329.     short                            property;
  1330.     EventRecord                        *theEvent;                    /*  -> The original event record of the mouse-down */
  1331. };
  1332.  
  1333. typedef struct DETCustomViewMouseDownBlock DETCustomViewMouseDownBlock;
  1334.  
  1335. struct DETKeyPressBlock {
  1336.     DETCallFunctions                reqFunction;
  1337.     DETCallBack                        callBack;
  1338.     long                            callBackPrivate;
  1339.     long                            templatePrivate;
  1340.     long                            instancePrivate;
  1341.     DETTargetSpecification            target;
  1342.     Boolean                            targetIsMainAspect;
  1343.     Boolean                            filler1;
  1344.     short                            property;
  1345.     EventRecord                        *theEvent;                    /*  -> The original event record of the key-press */
  1346. };
  1347.  
  1348. typedef struct DETKeyPressBlock DETKeyPressBlock;
  1349.  
  1350. struct DETPasteBlock {
  1351.     DETCallFunctions                reqFunction;
  1352.     DETCallBack                        callBack;
  1353.     long                            callBackPrivate;
  1354.     long                            templatePrivate;
  1355.     long                            instancePrivate;
  1356.     DETTargetSpecification            target;
  1357.     Boolean                            targetIsMainAspect;
  1358.     Boolean                            filler1;
  1359.     short                            property;
  1360.     short                            modifiers;                    /*  -> Modifiers at paste time (option/control/command/shift keys) */
  1361. };
  1362.  
  1363. typedef struct DETPasteBlock DETPasteBlock;
  1364.  
  1365. struct DETCustomMenuSelectedBlock {
  1366.     DETCallFunctions                reqFunction;
  1367.     DETCallBack                        callBack;
  1368.     long                            callBackPrivate;
  1369.     long                            templatePrivate;
  1370.     long                            instancePrivate;
  1371.     DETTargetSpecification            target;
  1372.     Boolean                            targetIsMainAspect;
  1373.     Boolean                            filler1;
  1374.     short                            menuTableParameter;            /*  -> The "property" field from the custom menu table */
  1375. };
  1376.  
  1377. typedef struct DETCustomMenuSelectedBlock DETCustomMenuSelectedBlock;
  1378.  
  1379. struct DETCustomMenuEnabledBlock {
  1380.     DETCallFunctions                reqFunction;
  1381.     DETCallBack                        callBack;
  1382.     long                            callBackPrivate;
  1383.     long                            templatePrivate;
  1384.     long                            instancePrivate;
  1385.     DETTargetSpecification            target;
  1386.     Boolean                            targetIsMainAspect;
  1387.     Boolean                            filler1;
  1388.     short                            menuTableParameter;            /*  -> The "property" field from the custom menu table */
  1389.     Boolean                            enable;                        /* <-  Whether to enable the menu item */
  1390.     Boolean                            filler2;
  1391. };
  1392.  
  1393. typedef struct DETCustomMenuEnabledBlock DETCustomMenuEnabledBlock;
  1394.  
  1395. struct DETForwarderListItem {
  1396.     struct DETForwarderListItem        **next;                        /* Pointer to next item, or nil */
  1397.     AttributeTag                    attributeValueTag;            /* Tag of new templates (0 for none) */
  1398.     PackedPathName                    rstrs;                        /* Record type (empty if none), attrbute type (empty if none),
  1399.                                                 list of template names to forward to */
  1400. };
  1401.  
  1402. typedef struct DETForwarderListItem **DETForwarderListHandle;
  1403.  
  1404. struct DETDynamicForwardersBlock {
  1405.     DETCallFunctions                reqFunction;
  1406.     DETCallBack                        callBack;
  1407.     long                            callBackPrivate;
  1408.     long                            templatePrivate;
  1409.     DETForwarderListHandle            forwarders;                    /* <-  List of forwaders */
  1410. };
  1411.  
  1412. typedef struct DETDynamicForwardersBlock DETDynamicForwardersBlock;
  1413.  
  1414. struct DETDynamicResourceBlock {
  1415.     DETCallFunctions                reqFunction;
  1416.     DETCallBack                        callBack;
  1417.     long                            callBackPrivate;
  1418.     long                            templatePrivate;
  1419.     long                            instancePrivate;
  1420.     DETTargetSpecification            target;
  1421.     Boolean                            targetIsMainAspect;
  1422.     Boolean                            filler1;
  1423.     ResType                            resourceType;                /*  -> The resource type being requested */
  1424.     short                            propertyNumber;                /*  -> The property number of the resource being requested */
  1425.     short                            resourceID;                    /*  -> The resource ID (base ID + property number) of the resource */
  1426.     Handle                            theResource;                /* <-  The requested resource */
  1427. };
  1428.  
  1429. typedef struct DETDynamicResourceBlock DETDynamicResourceBlock;
  1430.  
  1431. union DETCallBlock {
  1432.     DETProtoCallBlock                protoCall;
  1433.     DETInitBlock                    init;
  1434.     DETExitBlock                    exit;
  1435.     DETInstanceInitBlock            instanceInit;
  1436.     DETInstanceExitBlock            instanceExit;
  1437.     DETInstanceIdleBlock            instanceIdle;
  1438.     DETPropertyCommandBlock            propertyCommand;
  1439.     DETMaximumTextLengthBlock        maximumTextLength;
  1440.     DETViewListChangedBlock            viewListChanged;
  1441.     DETPropertyDirtiedBlock            propertyDirtied;
  1442.     DETValidateSaveBlock            validateSave;
  1443.     DETDropQueryBlock                dropQuery;
  1444.     DETDropMeQueryBlock                dropMeQuery;
  1445.     DETAttributeCreationBlock        attributeCreationBlock;
  1446.     DETAttributeNewBlock            attributeNew;
  1447.     DETAttributeChangeBlock            attributeChange;
  1448.     DETAttributeDeleteBlock            attributeDelete;
  1449.     DETItemNewBlock                    itemNew;
  1450.     DETPatternInBlock                patternIn;
  1451.     DETPatternOutBlock                patternOut;
  1452.     DETShouldSyncBlock                shouldSync;
  1453.     DETDoSyncBlock                    doSync;
  1454.     DETOpenSelfBlock                openSelf;
  1455.     DETConvertToNumberBlock            convertToNumber;
  1456.     DETConvertToRStringBlock        convertToRString;
  1457.     DETConvertFromNumberBlock        convertFromNumber;
  1458.     DETConvertFromRStringBlock        convertFromRString;
  1459.     DETCustomViewDrawBlock            customViewDraw;
  1460.     DETCustomViewMouseDownBlock        customViewMouseDown;
  1461.     DETKeyPressBlock                keyPress;
  1462.     DETPasteBlock                    paste;
  1463.     DETCustomMenuSelectedBlock        customMenuSelected;
  1464.     DETCustomMenuEnabledBlock        customMenuEnabled;
  1465.     DETDynamicForwardersBlock        dynamicForwarders;
  1466.     DETDynamicResourceBlock            dynamicResource;
  1467. };
  1468. typedef union DETCallBlock DETCallBlock;
  1469.  
  1470. typedef DETCallBlock *DETCallBlockPtr;
  1471.  
  1472. enum {
  1473.     uppDETCallBackProcInfo = kPascalStackBased
  1474.          | RESULT_SIZE(SIZE_CODE(sizeof(OSErr)))
  1475.          | STACK_ROUTINE_PARAMETER(1, SIZE_CODE(sizeof(DETCallBlock*)))
  1476.          | STACK_ROUTINE_PARAMETER(2, SIZE_CODE(sizeof(DETCallBackBlockPtr)))
  1477. };
  1478.  
  1479. #if GENERATINGCFM
  1480. #define CallDETCallBackProc(userRoutine, callBlockPtr, callBackBlockPtr)        \
  1481.         CallUniversalProc((UniversalProcPtr)(userRoutine), uppDETCallBackProcInfo, (callBlockPtr), (callBackBlockPtr))
  1482. #else
  1483. #define CallDETCallBackProc(userRoutine, callBlockPtr, callBackBlockPtr)        \
  1484.         (*(userRoutine))((callBlockPtr), (callBackBlockPtr))
  1485. #endif
  1486.  
  1487. #if GENERATINGCFM
  1488. #define NewDETCallBackProc(userRoutine)        \
  1489.         (DETCallBackUPP) NewRoutineDescriptor((ProcPtr)(userRoutine), uppDETCallBackProcInfo, GetCurrentArchitecture())
  1490. #else
  1491. #define NewDETCallBackProc(userRoutine)        \
  1492.         ((DETCallBackUPP) (userRoutine))
  1493. #endif
  1494.  
  1495.  
  1496. enum {
  1497.     kDETCallForOther            = 1,                            /* Call for things not listed below (also auto-enabled by DE if any of the below are enabled) */
  1498.     kDETCallForIdle                = 2,                            /* kDETcmdIdle */
  1499.     kDETCallForCommands            = 4,                            /* kDETcmdPropertyCommand, kDETcmdSelfOpen */
  1500.     kDETCallForViewChanges        = 8,                            /* kDETcmdViewListChanged, kDETcmdPropertyDirtied, kDETcmdMaximumTextLength */
  1501.     kDETCallForDrops            = 0x10,                            /* kDETcmdDropQuery, kDETcmdDropMeQuery */
  1502.     kDETCallForAttributes        = 0x20,                            /* kDETcmdAttributeCreation, kDETcmdAttributeNew, kDETcmdAttributeChange, kDETcmdAttributeDelete */
  1503.     kDETCallForValidation        = 0x40,                            /* kDETcmdValidateSave */
  1504.     kDETCallForKeyPresses        = 0x80,                            /* kDETcmdKeyPress and kDETcmdPaste */
  1505.     kDETCallForResources        = 0x100,                        /* kDETcmdDynamicResource */
  1506.     kDETCallForSyncing            = 0x200,                        /* kDETcmdShouldSync, kDETcmdDoSync */
  1507.     kDETCallForEscalation        = 0x8000,                        /* All calls escalated from the next lower level */
  1508.     kDETCallForNothing            = 0,                            /* None of the above
  1509.     * All of the above */
  1510.     kDETCallForEverything        = 0xFFFFFFFF
  1511. };
  1512.  
  1513. typedef pascal OSErr (*DETCallProcPtr)(DETCallBlockPtr callBlockPtr);
  1514.  
  1515. #if GENERATINGCFM
  1516. typedef UniversalProcPtr DETCallUPP;
  1517. #else
  1518. typedef DETCallProcPtr DETCallUPP;
  1519. #endif
  1520.  
  1521. enum {
  1522.     uppDETCallProcInfo = kPascalStackBased
  1523.          | RESULT_SIZE(SIZE_CODE(sizeof(OSErr)))
  1524.          | STACK_ROUTINE_PARAMETER(1, SIZE_CODE(sizeof(DETCallBlockPtr)))
  1525. };
  1526.  
  1527. #if GENERATINGCFM
  1528. #define NewDETCallProc(userRoutine)        \
  1529.         (DETCallUPP) NewRoutineDescriptor((ProcPtr)(userRoutine), uppDETCallProcInfo, GetCurrentArchitecture())
  1530. #else
  1531. #define NewDETCallProc(userRoutine)        \
  1532.         ((DETCallUPP) (userRoutine))
  1533. #endif
  1534.  
  1535. #if GENERATINGCFM
  1536. #define CallDETCallProc(userRoutine, callBlockPtr)        \
  1537.         CallUniversalProc((UniversalProcPtr)(userRoutine), uppDETCallProcInfo, (callBlockPtr))
  1538. #else
  1539. #define CallDETCallProc(userRoutine, callBlockPtr)        \
  1540.         (*(userRoutine))((callBlockPtr))
  1541. #endif
  1542.  
  1543. typedef DETCallUPP DETCall;
  1544.  
  1545. /* This following macro saves you from having to dig out the call-back pointer from the call block: */
  1546. #define CallBackDET(callBlockPtr, callBackBlockPtr)  CallDETCallBackProc(callBlockPtr->protoCall.callBack,callBlockPtr,callBackBlockPtr)
  1547. #endif /* REZ */
  1548. #define kSAMFirstDevProperty kDETFirstDevProperty + 10
  1549. #define kSAMAspectUserName kDETFirstDevProperty + 1
  1550. #define kSAMAspectKind kDETFirstDevProperty + 2
  1551. #define kSAMAspectCannotDelete kDETFirstDevProperty + 3
  1552. #define kSAMAspectSlotCreationInfo kDETFirstDevProperty + 4
  1553. #define kDETAdminVersion -978
  1554. #ifndef REZ
  1555.  
  1556. #if PRAGMA_IMPORT_SUPPORTED
  1557. #pragma import off
  1558. #endif
  1559.  
  1560. #if PRAGMA_ALIGN_SUPPORTED
  1561. #pragma options align=reset
  1562. #endif
  1563.  
  1564. #ifdef __cplusplus
  1565. }
  1566. #endif
  1567.  
  1568. #endif /* REZ */
  1569. #endif /* __OCETEMPLATES__ */
  1570.